//
//  YJImagePickerController.h
//  CToolBox
//
//  Created by crj on 16/9/7.
//  Copyright © 2016年 oyf. All rights reserved.
//

#import <Foundation/Foundation.h>

typedef NS_ENUM(NSInteger, YJImagePickerType) {

    YJImagePickerTypeLibrary,
    YJImagePickerTypeCamera
};

@interface YJImagePickerController : NSObject

@property (nonatomic, strong) UIImagePickerController *imagePicker;


- (instancetype)initWithController:(UIViewController *)controller;


- (void)openWithAllowsEditing:(BOOL)allowsEditing size:(CGSize)size didFinish:(void(^)(UIImage *image))didFinish;

- (void)openWithAllowsEditing:(BOOL)allowsEditing
                         size:(CGSize)size
                   pickerType:(YJImagePickerType)type
                    didFinish:(void(^)(UIImage *image))didFinish;

@end
